PORTNAME=	balsa
PORTVERSION=	2.6.4
CATEGORIES=	mail gnome
MASTER_SITES=	http://pawsa.fedorapeople.org/balsa/
DIST_SUBDIR=	gnome

MAINTAINER=	gnome@FreeBSD.org
COMMENT=	Mail reader for the GNOME desktop
WWW=		https://pawsa.fedorapeople.org/balsa/

LICENSE=	GPLv2

BUILD_DEPENDS=	gnome-keyring:security/gnome-keyring \
		itstool:textproc/itstool \
		yelp-tools>=0:textproc/yelp-tools
LIB_DEPENDS=	libgmime-3.0.so:mail/gmime30 \
		libgnutls.so:security/gnutls \
		libgpgme.so:security/gpgme \
		libfribidi.so:converters/fribidi \
		libical.so:devel/libical \
		libsecret-1.so:security/libsecret \
		libgcr-base-3.so:security/gcr
RUN_DEPENDS=	gnome-keyring:security/gnome-keyring

USES=		cpe desktop-file-utils gettext gnome meson perl5 \
		pkgconfig tar:xz
USE_GNOME=	cairo gdkpixbuf2 glib20 gtk30
CPE_VENDOR=	gnome
MESON_ARGS=	-Dhtml-widget=no \
		-Dgcr=true
#CPPFLAGS+=	-I${LOCALBASE}/include
#LDFLAGS+=	-L${LOCALBASE}/lib ${ICONV_LIB}

OPTIONS_SUB=	yes
OPTIONS_DEFINE=	GTKSPELL GTKSV
OPTIONS_DEFAULT=GTKSPELL GTKSV
GTKSPELL_DESC=	Spell checking support
GTKSV_DESC=	GtkSourceview support
GTKSPELL_MESON_ON=	-Dspell-checker=gspell
GTKSPELL_LIB_DEPENDS=	libgspell-1.so:textproc/gspell
GTKSPELL_MESON_OFF=	-Dspell-checker=internal
GTKSPELL_LIB_DEPENDS_OFF=	libenchant-2.so:textproc/enchant2
GTKSV_MESON_TRUE=	gtksourceview
GTKSV_USE=		GNOME=gtksourceview4

.include <bsd.port.mk>
